The present invention relates to high availability computer storage systems and, more particularly, to methods for mirroring disk drives within a network.
The increased reliance by business on On-Line Transaction Processing and Decision Support Systems has increased the demand for high availability systems since these systems are critical to the functioning of day-to-day activities in many businesses. These systems are not only essential for the support of normal daily operations, but they also store critically important customer and corporate data. Continuous availability is no longer an ideal; it is a necessity for many companies. Longer work days, expansion into new markets and customer demand for more efficient service create an expanded requirement for increased system availability. Users are demanding a means of ensuring very high availability of their applications and the access to data that permits them to accomplish their tasks and provide the highest levels of customer service. Interruption of workflow due to system failure is expensive and it can cause the loss of business. The need to increase computer system availability is becoming one of businesses key concerns.
Implementation of client/server computing is growing throughout today""s businessesxe2x80x94for key business applications as well as electronic mail, distributed databases, file transfer, retail point-of-sale, inter-networking, and other applications. It is possible for companies to gain competitive advantages from client/server environments by controlling the cost of the technology components through economies of scale and the use of clustered computing resources. There is a boost in productivity when businesses have high availability and easy access to information throughout the corporate enterprise.
An important component of a high-availability client/server system is a reliable, fault-tolerant data storage system. In some networked or xe2x80x9cclusteredxe2x80x9d multiple server arrangements, the physical data storage system may be a shared RAID (Redundant Array of Inexpensive Disks) disk array system, or a shared pair of disk drives or disk arrays operating in a mirrored arrangement.
A disk mirroring system, also referred to as a RAID Level 1 system, typically consists of two equal-capacity disk drives that mirror one another. One disk drive contains a duplicate of all the files contained on the other disk drive, each drive essentially functioning as a backup for the other disk drive. Should one of the disk drives fail all the data and applications contained on the failed drive are available from the remaining disk drive. The mirror drives may be co-located such as in a single personal computer or server computer, or may reside at different locations within a network. The drives may be logical drives, partitions or drive arrays. They do not need to be equivalent in all aspects or of equal capacity.
Most disk mirroring procedures utilizing shared drives will write or update both mirror drives synchronously. In systems performing disk mirroring with non-shared drives over a network, writes directed to a primary drive are received and forwarded to the secondary mirror drive. Upon receipt from the secondary drive of an acknowledgement signal indicating a successful update of the secondary drive, the write to the primary is completed.
A computer system including multiple servers and a pair of shared disk drives is shown in FIG. 1. FIG. 1 provides a diagram of clustered or networked computers having a primary server 101 and a secondary server 103 in a fail-over pair arrangement. Primary server 101 is the preferred application server of the pair, and secondary server 103 preferably provides fail-over protection for the primary server. The primary and secondary servers are coupled through a network bus system 105 to a plurality of client computers 107 though 109. The primary and secondary servers 101 and 103 each shares access to a pair of disk storage devices 111 and 113. Disk storage devices 111 and 113 are SCSI (Small Computer Systems Interface) disk drives or disk arrays connected to servers 101 and 103 through a pair of SCSI busses 115 and 117.
Primary disk storage device 111 and secondary disk storage device 113 are two equal-capacity storage devices that mirror each other. Each storage device contains a duplicate of all files contained on the other storage device, and a write or update to one storage device updates both devices in the same manner. In the event that either storage device fails, the data contained therein remains available to the system from the operational mirror storage device.
After the disk mirrors are established, the drives on the primary and secondary servers are synchronized, and both servers are up and running, disk mirroring conventionally proceeds as follows:
1. After the initial mirror is established, the system locks out all user access to the secondary drive 113. Reads and writes are not allowed to the secondary drive 113. The primary server drive 111 is accessible for both reads and writes.
2. Whenever the primary server 101 receives a write request for mirrored drive 111 the request is sent to the secondary mirrored drive 113 first. The secondary system 103 executes the write request on its mirrored drive and then sends the status of the write back to the primary server 101. The primary server 101 does nothing on the write request until the secondary server 103 returns its status.
3. When the secondary server 103 returns a successful status, the primary server 101 executes the write to its mirrored drive 111. Should an error occur while the secondary server 103 executes its mirrored drive write, the write process on the secondary server is terminated. The primary server then completes the write request on its mirrored drive and the status of the mirror then changes from Normal to Broken.
4. The secondary mirrored drive 113 is locked to all users once the mirror is created. Locking the secondary mirrored drive 113 ensures that data on both the primary and secondary mirrored drives is not corrupted through an inadvertent write to the secondary mirrored drive. When a mirror is deleted, the secondary mirrored drive is unlocked and full access is again allowed to both the primary drive 111 and secondary drive 113.
In disk mirroring applications, particularly disk mirroring applications utilizing non-shared drives over a network, it can be a very expensive operation in terms of processing time and network bandwidth to write a disk block from one disk drive to its mirror disk drive. A method for synchronizing mirrored disk volumes and writing data to a mirrored drive that reduces the overall expense of disk mirroring operations, particularly when mirroring non-shared disk drives over a network, is desired.
It is therefore an object of the present invention to provide a new and method for mirroring storage devices that reduces the expense of synchronizing mirrored disk volumes and writing data to a mirrored drive.
It is another object of the present invention to provide such a method for mirroring storage devices over a network that reduces the processing time and network bandwidth required to write a disk block from a primary disk drive to a secondary mirror disk drive.
It is yet another object of the present invention to provide a new and useful method for mirroring storage devices that optimizes disk mirror synchronization operations.
It is a still further object of the present invention to provide a new and useful method for mirroring storage devices that optimizes disk mirror write operations.
There is provided, in accordance with the present invention, methods for duplicating data stored on a first storage device on a second storage device, and for duplicating data written to a first data storage device on a second data storage device.
The method for duplicating data stored on a first storage device on a second storage device comprises the steps of: examining each data block contained within the first storage device and identifying data blocks that contain only zero data and data blocks containing non-zero data; sending a request to the second storage device to create a zeroed block corresponding to each data block that contains only zero data; and writing to the second storage device a copy of each data block containing non-zero data.
The method for duplicating data written to a first data storage device on a second data storage device comprises the steps of: intercepting a write request directed to the first storage device, the write request including at least one data block; and for each data block included within the write request: (1) examining the data block to determine if the data block contains only zero data; (2) if the data block contains only zero data, sending a request to the second storage device to create a zeroed block; and (3) if the data block contains non-zero data, transmitting the data block to the second storage device.
The above and other objects, features, and advantages of the present invention will become apparent from the following description and the attached drawings.